home *** CD-ROM | disk | FTP | other *** search
/ Network CD 1 / Network CD.iso / tbag / 51-60 / tb54 / docs / kcd.docs < prev    next >
Text File  |  1991-04-14  |  5KB  |  169 lines

  1.                 K C D     ( Karsten Change Directory )
  2.                -------      -       -      -
  3.  
  4. This is a very short documentation of the program KCD.
  5. This program is in the public domain, so feel free to change the 
  6. source code to make the program perhaps better than it is now.
  7.  
  8.  
  9. What is KCD ?
  10.  
  11.   KCD is a program, that allows you to change comfortably into another
  12.   directory within a shell. Every harddisk owner knows the problem, when
  13.   he wants to change into another, little frequent subdirectory. He
  14.   always has to remember the whole pathname and type it in correctly.
  15.   Mostly he needs several tries until he is in the right directory.
  16.  
  17.  
  18. How does KCD work ?
  19.  
  20.   KCD makes a list of your harddisks subdirectories, which is read
  21.   every time you call KCD. This structure is shown in a window and you only
  22.   have to click on this directory you want to change to. You can scroll
  23.   the list by moving the mouse to the first or last line. KCD generates
  24.   a pathname, which can be used for several actions.
  25.   
  26.  
  27. Installation :
  28.  
  29.   * Copy th program KCD to your favorite 'bin'-directory.
  30.   * Write a text file called 'kcd.cfg' in your 's:'-directory. Here you
  31.     can tell KCD what you really want to do with the generated pathname.
  32.     ( Please read the next section! )
  33.   * Because KCD is very general, you perhaps have to call it from a 
  34.     script file.
  35.     I use KCD to get an environment variable 'newpath', in which
  36.     the pathname is stored. The pathname is then available with $newpath.
  37.  
  38.     A script file 'NewCD' might look like:
  39.       
  40.          .key dir/a
  41.          KCD <dir>
  42.          cd $newpath
  43.  
  44.  
  45. The config file 's:kcd.cfg' :
  46.  
  47.   You first have to write a configuration file in the s: directory named
  48.   'kcd.cfg'. Here you can tell KCD your environment.
  49.  
  50.   My file looks like that:
  51.  
  52.      TEXTCOLOR 1   ; Text color = pen1
  53.      MARKCOLOR 3   ; Mark color = pen3
  54.      LINECOLOR 2   ; Line color = pen2
  55.  
  56.      ; Devices (logical or physical),
  57.      ; which have to be examined
  58.  
  59.      ROOTDIR UHD:
  60.      ROOTDIR SHD:
  61.  
  62.      WINDOWX 10    ; left upper corner of the shown window
  63.      WINDOWY 11
  64.  
  65.      DELAY   0     ; no delay
  66.      SCROLL  8     ; 8 pixels to scroll
  67.      SORT    1     ; sort in alphabetic order
  68.  
  69.      ; Command that has to be executed
  70.  
  71.      COMMAND 'setenv newpath %s'
  72.  
  73.      ; Directories you don't like in the list
  74.  
  75.      NOT     SHD:devs
  76.      NOT     SHD:empty
  77.      NOT     SHD:fonts
  78.      NOT     UHD:TeX
  79.  
  80.  
  81.  
  82.   The meaning of the keywords
  83.  
  84.     TEXTCOLOR :  Color of the directory names
  85.                  Default : 1
  86.  
  87.     MARKCOLOR :  Color of the selected directory
  88.                  Default : 3
  89.  
  90.     LINECOLOR :  Color of the lines
  91.                  Default : 2
  92.  
  93.     ROOTDIR   :  Name of devices (logical,physical) to put in the list.
  94.                  Default : DH0:
  95.                  For each device you need an entry ROOTDIR <device>.
  96.  
  97.     WINDOWX,
  98.     WINDOWY   :  Position of the window.
  99.                  Default : WINDOWX 0 , WINDOWY 0
  100.  
  101.     DELAY     :  scroll speed ( 0 = quick )
  102.                  Default : 0
  103.  
  104.     SCROLL    :  Number of pixels to scroll. Allowed is 1 , 2 , 4 , 8
  105.                  Default : 8
  106.  
  107.     SORT      :  How to sort the list.
  108.                    0 = not sorted
  109.                    1 = sorted in alphabetic order
  110.                   -1 = sorted in reverse alphabetic order
  111.                  Default : 0
  112.  
  113.     NOT       :  The given directory and all subdirectories will not be in
  114.                  the list.
  115.                  Default : none
  116.  
  117.     COMMAND   :  Command that will be executed, when the pathname is generated.
  118.                  You have to put the commandstring into quotes ('...').
  119.                  It has to contain the control character %s .
  120.                  Default: 'setenv newpath %s'
  121.  
  122.  
  123. Fist use of KCD:
  124.  
  125.  * Type :  KCD -l <RETURN>
  126.  
  127.    Now KCD generates a file in the s: directory named 'kcd.antilist'.
  128.    With an editor you can put an '-' in front of every entry, you don't
  129.    like in your list.
  130.  
  131.  * Type : KCD -n <RETURN>
  132.  
  133.    The file 's:kcd.list' will be generated or updated.
  134.  
  135.  * Geben Sie nun ein : KCD <RETURN>
  136.  
  137.    The structure of your device is shown in a window.
  138.  
  139. REMEMBER:
  140.   KCD will not change automatically to the selected directory. It
  141.   only executes the command string ( default or set by COMMAND in
  142.   the config file ).
  143.  
  144.  
  145. Also possible calls of KCD:
  146.  
  147.   1. KCD -?
  148.  
  149.      - Informations about how to use KCD.
  150.  
  151.   2. KCD <directory>
  152.      e.g. KCD sys:devs
  153.  
  154.      - The given directory is examined to other subdirectories and
  155.        then shown in the window.
  156.  
  157.   3. KCD <logical device>
  158.      e.g. KCD devs:
  159.  
  160.   3. KCD <physical device>
  161.      e.g. KCD df2:
  162.  
  163.  
  164. Others:
  165.   * Works well on an A500 with KS1.3 and WB1.3
  166.   * No bugs known
  167.   * The directory names may not contain any BLANK.
  168.  
  169.